package core.modules.communication.test;

import javax.management.MBeanServer;

import org.jboss.remoting.InvocationRequest;
import org.jboss.remoting.ServerInvocationHandler;
import org.jboss.remoting.ServerInvoker;
import org.jboss.remoting.callback.InvokerCallbackHandler;

import core.modules.database.corebase.AdministratorTokenCore;

public class MyInvocationHandler implements ServerInvocationHandler {
	int counter = 1;
	public Object invoke(InvocationRequest invocation) {
		System.out.println("New Message incoming!");
		//return "Received:" + ((AdministratorTokenCore)invocation.getParameter()).getValue() + " " + counter++;
		return invocation.getParameter();
	}

	public void addListener(InvokerCallbackHandler arg0) {

	}

	public void removeListener(InvokerCallbackHandler arg0) {

	}

	public void setInvoker(ServerInvoker arg0) {

	}

	public void setMBeanServer(MBeanServer arg0) {

	}

}
